package com.bdqn.carrental.service;

import com.bdqn.carrental.dao.CustomerMapper;
import com.bdqn.carrental.pojo.CustomerEntity;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
@MapperScan("com.bdqn.carrental.dao")
public class CustomerServiceImpl implements CustomerService {

    @Autowired
    CustomerMapper customerMapper;
/*    @Override
    public List<CustomerEntity> findAll() {
        List<CustomerEntity> list=customerMapper.findAll();
        return list;
    }*/
/*手机模糊查询*/
    @Override
    public List<CustomerEntity> SelectPhone(String phone) {
        List<CustomerEntity> lists=customerMapper.SelectPhone(phone);
        return lists;
    }

    @Override
    public List<CustomerEntity> selectHY(String id) {
        List<CustomerEntity> selectlist=customerMapper.selectHY(id);
        return selectlist;
    }

    @Override
    public int delCustomers(String phone) {
        return customerMapper.delCustomers(phone);

    }


}
